<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <meta name="description" content="Partytown Test Page" />

    <title>Mermaid 🎉</title>

    <script>
      partytown = {
        logCalls: true,
        logGetters: true,
        logSetters: true,
        logImageRequests: true,
        logMainAccess: true,
        logSendBeaconRequests: true,
        logStackTraces: false,
        logScriptExecution: true,
      };
    </script>
    <script src="/~partytown/debug/partytown.js"></script>

    <style>
      body {
        font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial, sans-serif,
          Apple Color Emoji, Segoe UI Emoji;
        font-size: 12px;
      }
      h1 {
        margin: 0 0 15px 0;
      }
      ul {
        list-style-type: none;
        margin: 0;
        padding: 0;
      }
      a {
        display: block;
        padding: 16px 8px;
      }
      a:link,
      a:visited {
        text-decoration: none;
        color: blue;
      }
      a:hover {
        background-color: #eee;
      }
      li {
        display: flex;
        margin: 15px 0;
      }
      li strong,
      li code,
      li button {
        white-space: nowrap;
        flex: 1;
        margin: 0 5px;
      }
    </style>
    <script>
      setTimeout(() => {
        let errors = document.querySelector('[data-pterror]');
        let elm = document.createElement('div');
        elm.id = 'pterrors';
        if (errors) {
          elm.textContent = 'ERROR';
        } else {
          elm.textContent = 'NO ERROR';
        }
        document.body.appendChild(elm);
      }, 2000);
    </script>
  </head>
  <body>
    <h1>Mermaid 🎉</h1>

    <script type="text/partytown" src="mermaid.js"></script>

    <div class="mermaid">graph TD; A-->B; A-->C; B-->D; C-->D;</div>

    <script type="text/partytown">
      mermaid.initialize({ startOnLoad: true });
    </script>

    <hr />
    <p><a href="/tests/integrations/mermaid/standard.html">Standard Mermaid</a></p>
    <p><a href="https://mermaid-js.github.io/mermaid/">Mermaid Docs</a></p>
    <p><a href="/tests/">All Tests</a></p>
  </body>
</html>
